<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@include file="../common/jspcommon.jsp"%>

<script type="text/javascript">
var albumIden = "";

function taPhotoAll() {
	$("#content_detail").load("taPhotoPage.htm?family=${family}");
}
function albumInfoUploadPhoto(album) {
	if (IsNull(album)) {
		if (!IsNull(albumIden)) {
			album = albumIden;
		} else {
			album = "";
		}
	}
	$("#photoContent").load("uploadPhoto.htm?albumId=" + album);
}

function friendAlbum() {
	$("#content_detail").load("albumFriend.htm");
}

//加载详细照片页面
function albumPagePhoto(album) {
	albumIden = album;
	$("#content_detail").load("taPhotoPage.htm?family=${family}&album=" + album);
}
//相册编辑页面
function albumPageEdit(album) {
	albumIden = album;
	$("#photoContent").load("albumEdit.htm?album=" + album);
}
</script>

<!--内容快-->
<div class="h_main2">
	<div class="h_data">
		<h2>
			<img src="images/home_images/ico28.png" alt="相册" />
			相册
		</h2>
		<div class="h_newNews">
			<ul>
				<li id="newNews1" onclick="albumInfo();" class="h_newNewsHover">
					<a>TA家的照片</a>
				</li>
				<!-- 
						<li id="newNews2" onclick="friendAlbum();">
							<a>邻居的照片</a>
						</li>
						 -->
			</ul>
			<div class="clear"></div>
		</div>
		<div id="photoContent">
			<div class="h_newNews_box">
				<div class="h_newNews_text" id="con_newNews_1"
					style="display: block;">
					<div class="data_h_newNews_nav" id="my_photo_top">
						<a href="javascript:void(0);" class="current"
							onclick="albumInfo();">TA家的照片专辑</a>|
						<a href="javascript:void(0);" onclick="taPhotoAll();">TA家的全部照片</a>
					</div>
					<div class="clear"></div>
					<div id="photoBox">
						<div class="photos_box">
							<ul>
							<c:if test="${albumPageModel.list == null || fn:length(albumPageModel.list) < 1}">
							<div id="base_info_tip_success" class="success">TA家暂时没有照片专辑。</div>
							</c:if>
								<c:forEach items="${albumPageModel.list}" var="album">
									<li>
										<div class="phots_img">
											<div
													style="width: 153px; height: 112px; overflow: hidden; text-align: center;">
											<a href="javascript:void(0);"
												onclick="albumPagePhoto('${album.identifier}')">
												
													<img
														<c:choose>
																	<c:when test="${album.cover!=null && album.cover!=''}">
																		src="${album.cover}"
																	</c:when> 
																	<c:otherwise>
																		src="images/avatar/album.jpg"
																	</c:otherwise>
																</c:choose>
														alt="相册" />
												 </a>
												 </div>
											<span> <a href="javascript:void(0);"
												class="phots_imgName"><c:out value="${album.name}"></c:out>
											</a></span>
										</div>
									</li>
								</c:forEach>
								<div class="clear"></div>
							</ul>
						</div>
						<div class="h_page" id="pager"></div>
					</div>
				</div>

			</div>
		</div>
	</div>
</div>
<div class="clear"></div>

